<template>
	<view class="">
		 <view class="">
			<Calendar :switchMonth="true"  :date="currentData" :themeColor="'#13b1eb'"  @callback="getDate" />
				<view class="Determine" @click="sure">
					确定
				</view>
			</Calendar>
		</view>
	</view>
</template>

<script>
	import Calendar from "@/components/mobile-calendar-simple/Calendar.vue";
	export default{
		data(){
			return{
				currentData:'请选择'
			}
		},
		created(){
			// 获取当前时间
			let curRen = new Date().toLocaleDateString();
			this.currentData = curRen;
		},
		methods:{
			
			//获取回调的日期数据
			getDate(date){
				uni.setStorageSync("current_date", date);
				console.log(date)
			},
			sure:function(){
				uni.navigateBack({
					delta: 1
				})
			}
		},
		onLoad(){
			
		},
		components:{
			Calendar
		}
	}
	
</script>

<style>
	.Determine{
		height: 100upx;
		line-height: 100upx;
		width: 100%;
		position: fixed;
		bottom: 0upx;
		left: 0upx;
		background: #f60;
		text-align: center;
		color: #fff;
		z-index: 100;
	}
</style>
